Skip to content

fix(session_start): point an installed hook at plumb hooks, not at installing it - #548

Merged
atlas-from-plumb merged 6 commits into
mainfrom
atlas/stamp-notice-remedy
Oct 1, 2026
Merged

atlas-from-plumb merged 6 commits into
mainfrom
atlas/stamp-notice-remedy

Conversation

@atlas-from-plumb

Copy link
Copy Markdown
Collaborator

Why

Found by dogfooding plumb from a Claude desktop Code-tab session running a daemon built before #531. The hook was installed and stamping, but the daemon didn't advertise plumb_agent, so the connector stripped the stamp. session_start's notice then said only "plumb hooks install claude-code stamps every call", which sent the caller in a circle to install something it already had.

Change

Both no-identity notices (refused and dormant) in internal/tools/session_start_stamp.go now add that plumb hooks says why the call was not stamped. #536 made plumb hooks status report a daemon that doesn't list plumb_agent, so that command gives the real reason.

Tests

TestStampChannelNotices_PointAnInstalledHookAtItsDiagnosis pins both notices. The brief-packet byte budget still passes. GOWORK=off go test ./... -count=1 and -tags=integration ./internal/cli/: ok. The CHANGELOG entry is under 0.20.4 (unreleased), and the placement check passes.

🤖 Generated with Claude Code

atlas-from-plumb and others added 4 commits October 1, 2026 07:36
…installing it

When a call arrived without a per-call identity, session_start's notices
said only "`plumb hooks install claude-code` stamps every call". With the
hook already installed, the usual cause is a daemon too old to accept the
key Claude desktop's connector passes through (found by dogfooding on a
pre-#531 build). The advice sent the caller round in a circle. Both
notices now add that `plumb hooks` says why the call was not stamped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Plumb-Session: scarlet-viper
…xplains the call

The stamp notices told a caller with an installed hook that `plumb hooks` says
why the call was not stamped. It does not always: for a missing or stale hook,
or a daemon that is old or does not list plumb_agent, it reports the fault, but
with a current hook and a daemon that accepts the stamp it has nothing to
report, so the promise sent that reader round in a circle again.

Both notices now say that, if the hook is installed, `plumb hooks` checks it and
the daemon. The clause is also twelve bytes shorter than the one it replaces,
which matters: in a loaded workspace the brief packet carrying the dormant
notice is within a few bytes of its 1536-byte bound, and the unchanged byte
budget test never renders either notice.

The test pins the new clause and rejects "says why". Mutants run through
go test -overlay were all killed: the pointer dropped from the refused notice,
"says why" restored in either notice, and the install remedy dropped from the
dormant notice. The CHANGELOG entry now describes what the command reports.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Plumb-Session: giant-bison

@golimpio golimpio left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taken over from a stalled session and independently reviewed. One finding was fixed with red-first tests and mutants, and the change is consistent with #562 and #570. CI is green.

golimpio
golimpio previously approved these changes Oct 1, 2026

@golimpio golimpio left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-approving after update-branch.

@golimpio golimpio left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Re-approving after a clean merge of main (#552): the CHANGELOG adds lines with no deletions, and the build and targeted tests pass.

@atlas-from-plumb

Copy link
Copy Markdown
Collaborator Author

Correction to the re-approval note: after merging main, only the build and the size and changelog checks ran locally. The targeted test run didn't start, because the test cache directory was missing. The test gate for this head is CI's full run, which auto-merge waits for.

@atlas-from-plumb
atlas-from-plumb merged commit 3462daf into main Oct 1, 2026
9 checks passed
@golimpio
golimpio deleted the atlas/stamp-notice-remedy branch October 2, 2026 04:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants